package com.xoa.model.document;

import com.alibaba.fastjson.annotation.JSONField;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.Map;

/**
 * Created by pfl on 2017/8/1.
 */
public class DocumentModelFlowRunPrcs extends DocumentModelWithBLOBs {
    private String createrName; //创建人名
    private Integer prFlag;//发文状态
    private String prcsName;//步骤节点
    private Integer realPrcsId;//真实步骤ID  流程设计器中的步骤号
    private Integer step;//流程步骤  流程实例的步骤号
    private Date endTime;//流程结束时间
    private String codeName;

    private String curUserIdName;
    private String allUserIdName;

    private String flowName;

    private Integer frpId;

    // 办理时限
    private String timeOut;
    // 是否允许转交时设置办理时限(0-不允许,1-允许)
    private String timeOutModify;
    // 是否排除非工作时段(按排班类型)：(0-否,1-是,)
    private String timeOutAttend;
    // 超时计算方法(0-本步骤接收后开始计时,1-上一步骤转交后开始计时,)
    private String timeOutType;
    // 时限具体时间
    private String timeOutStr;
    // 工作接收时间
    private String prcsTime;
    // 工作创建时间
    private String createTime;
    // 是否超时
    private Boolean ifOutTime;
    //用户头像
    private  String avatar;

    private String opFlag;

    //用户uid
    private Integer uid;


    //当前步骤
    private String bz;

    //当前经办人
    private String currentPeople;

    //经办步骤
    private String jbbz;


    //流程状态
    private String state;

    //最后一步审批人
    private Map map;

    //状态
    private String state1;

    //并发判断
    private String state2;

    //并发步骤节点字符串
    private String branchCount;

    private Integer runId;

    private String userId;

    private String flowPrcs;

    private String comment;//数据库对应批注（现作于电建办公门户使用）

    private Map<String,Object> handles;//用来提示门户悬浮提示内容
    //timeOutFlag超时标志，对应数据库
    private String timeOutFlag;
    /** 工作等级 0-普通 1-紧急 2-特急 **/
    private Integer workLevel;

    // 下一步骤的状态 用于收回判断 1-未接收,2-办理中,3-转交下一步，下一步经办人无人接收,4-已办结,5-自由流程预设步骤,6-已挂起
    private String nextPrcsFlag;

    public String getNextPrcsFlag() {
        return nextPrcsFlag;
    }

    public void setNextPrcsFlag(String nextPrcsFlag) {
        this.nextPrcsFlag = nextPrcsFlag;
    }

    public Integer getWorkLevel() {
        return workLevel;
    }

    public void setWorkLevel(Integer workLevel) {
        this.workLevel = workLevel;
    }

    public String getTimeOutFlag() {
        return timeOutFlag;
    }

    public void setTimeOutFlag(String timeOutFlag) {
        this.timeOutFlag = timeOutFlag;
    }

    public Map<String, Object> getHandles() {
        return handles;
    }

    public void setHandles(Map<String, Object> handles) {
        this.handles = handles;
    }

    public String getComment() {
        return comment;
    }

    public void setComment(String comment) {
        this.comment = comment;
    }

    // 当前步骤办结时间
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date deliverTime;

    public Map getMap() {
        return map;
    }

    public void setMap(Map map) {
        this.map = map;
    }

    public Integer getFrpId() {
        return frpId;
    }

    public void setFrpId(Integer frpId) {
        this.frpId = frpId;
    }

    public Date getDeliverTime() {
        return deliverTime;
    }

    public void setDeliverTime(Date deliverTime) {
        this.deliverTime = deliverTime;
    }

    public Integer getUid() {
        return uid;
    }

    public void setUid(Integer uid) {
        this.uid = uid;
    }

    public String getOpFlag() {
        return opFlag;
    }

    public void setOpFlag(String opFlag) {
        this.opFlag = opFlag;
    }

    public String getAvatar() {
        return avatar== null ? "" : avatar.trim();
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public Boolean getIfOutTime() {
        return ifOutTime;
    }

    public void setIfOutTime(Boolean ifOutTime) {
        this.ifOutTime = ifOutTime;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }

    public void setTimeOutStr(String timeOutStr) {
        this.timeOutStr = timeOutStr;
    }

    public String getPrcsTime() {
        return prcsTime;
    }

    public void setPrcsTime(String prcsTime) {
        this.prcsTime = prcsTime;
    }

    public String getTimeOutStr() {
        return timeOutStr;
    }

    public String getTimeOut() {
        return timeOut;
    }

    public void setTimeOut(String timeOut) {
        this.timeOut = timeOut;
    }

    public String getTimeOutModify() {
        return timeOutModify;
    }

    public void setTimeOutModify(String timeOutModify) {
        this.timeOutModify = timeOutModify;
    }

    public String getTimeOutAttend() {
        return timeOutAttend;
    }

    public void setTimeOutAttend(String timeOutAttend) {
        this.timeOutAttend = timeOutAttend;
    }

    public String getTimeOutType() {
        return timeOutType;
    }

    public void setTimeOutType(String timeOutType) {
        this.timeOutType = timeOutType;
    }

    public String getFlowName() {
        return flowName;
    }

    public void setFlowName(String flowName) {
        this.flowName = flowName;
    }

    public String getCurUserIdName() {
        return curUserIdName;
    }

    public void setCurUserIdName(String curUserIdName) {
        this.curUserIdName = curUserIdName;
    }

    public String getAllUserIdName() {
        return allUserIdName;
    }

    public void setAllUserIdName(String allUserIdName) {
        this.allUserIdName = allUserIdName;
    }

    public String getCodeName() {
        return codeName;
    }

    public void setCodeName(String codeName) {
        this.codeName = codeName;
    }

    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    public Date getEndTime() {
        return endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public Integer getStep() {
        return step;
    }

    public void setStep(Integer step) {
        this.step = step;
    }

    public String getCreaterName() {
        return createrName;
    }

    public void setCreaterName(String createrName) {
        this.createrName = createrName;
    }

    public Integer getPrFlag() {
        return prFlag;
    }

    public void setPrFlag(Integer prFlag) {
        this.prFlag = prFlag;
    }

    @Override
    public String getPrcsName() {
        return prcsName;
    }

    @Override
    public void setPrcsName(String prcsName) {
        this.prcsName = prcsName;
    }

    public Integer getRealPrcsId() {
        return realPrcsId;
    }

    public void setRealPrcsId(Integer realPrcsId) {
        this.realPrcsId = realPrcsId;
    }

    public String getBz() {
        return bz;
    }

    public void setBz(String bz) {
        this.bz = bz;
    }

    public String getCurrentPeople() {
        return currentPeople;
    }

    public void setCurrentPeople(String currentPeople) {
        this.currentPeople = currentPeople;
    }

    public String getJbbz() {
        return jbbz;
    }

    public void setJbbz(String jbbz) {
        this.jbbz = jbbz;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public String getState1() {
        return state1;
    }

    public void setState1(String state1) {
        this.state1 = state1;
    }

    public String getState2() {
        return state2;
    }

    public void setState2(String state2) {
        this.state2 = state2;
    }

    public String getBranchCount() {
        return branchCount;
    }

    public void setBranchCount(String branchCount) {
        this.branchCount = branchCount;
    }



    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    @Override
    public Integer getRunId() {
        return runId;
    }

    @Override
    public void setRunId(Integer runId) {
        this.runId = runId;
    }

    @Override
    public String getFlowPrcs() {
        return flowPrcs;
    }

    @Override
    public void setFlowPrcs(String flowPrcs) {
        this.flowPrcs = flowPrcs;
    }
}
